#include "config.h"


// 第2层全连接
void lenet_fc2(
    dtype d_in[FC2_IN_SIZE],
    dtype d_out[FC2_OUT_SIZE],
    dtype weights[FC2_OUT_SIZE][FC2_IN_SIZE],
    dtype bias[FC2_OUT_SIZE]
    ){
    
    for (int i = 0; i < FC2_OUT_SIZE; i++){
        dtype tmp = 0;
        for (int j = 0; j < FC2_IN_SIZE; j++){
            tmp += d_in[j] * weights[i][j];
        }
        d_out[i] = RELU(tmp + bias[i]);
    }
}
